import configparser


class Base_Config:

    def __init__(self):
        self.apiserver = {}

    def read_apiserver(self):
        config = configparser.ConfigParser()
        config.read('config/apiserver.config')
        for section in config.sections():
            self.apiserver[section] = {}
            for option in config.options(section):
                self.apiserver[section][option] = config.get(section, option)
        return self.apiserver

config = Base_Config()
apiserver = config.read_apiserver()
